From: Matthias Clasen Date: Thu, 24 Sep 2015 17:16:56 +0000 (-0400) Subject: shell_dbus_acquire_name: Don't leak error X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~1013^2^2~1181 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=7f1a258ff9fc768a7fc13e5c37e1fd6d7ab5c33b;p=gnome-shell.git shell_dbus_acquire_name: Don't leak error If fatal is not set, we return from this function in the error case. Don't leak the GError if that happens. --- diff --git a/src/main.c b/src/main.c index d984eec26..fb0ea4382 100644 --- a/src/main.c +++ b/src/main.c @@ -69,6 +69,7 @@ shell_dbus_acquire_name (GDBusProxy *bus, &error))) { g_printerr ("failed to acquire %s: %s\n", name, error->message); + g_clear_error (&error); if (!fatal) return; exit (1);